 <{extends file="<{$tempdir}>/public/admin.html"}>
  <{block name=extendjs}>
<script type="text/javascript" language="javascript" src="<{$siteurl}>/templates/<{$tempdir}>/public/js/artdialog/plugins/iframeTools.js"></script>
 <script type="text/javascript" language="javascript" src="<{$siteurl}>/templates/<{$tempdir}>/public/js/chart/highcharts.js"></script>
<script type="text/javascript" language="javascript" src="<{$siteurl}>/templates/<{$tempdir}>/public/js/chart/modules/exporting.js"></script>
<script type="text/javascript">


			function gotolink(obj){
			  var checkvalue = $(obj).val();
			  var linkis = siteurl+'/index.php?ctrl=adminpage&action=analysis&module=shop&selecttype=@selecttype@';
		   	window.location.href= linkis.replace('@selecttype@', checkvalue);
  }
		</script>


 <{/block}>
 <{block name=controlname}>店铺TOP10销售数据<{/block}>
 <{block name=bodylist}>
   <div style="width:auto;overflow-x:hidden;overflow-y:auto">
      	 <div class="tags">
          <div id="tagscontent">
<div style="text-align:center;height:30px;line-height:30px;widht:100%;">
            	 <input type="checkbox" name="selecttype" value="0" <{if empty($selecttype)}>checked<{/if}> onclick="gotolink(this);">所有
            	 <input type="checkbox" name="selecttype" value="1" <{if $selecttype == 1}>checked<{/if}> onclick="gotolink(this);">最近1月
            	 <input type="checkbox" name="selecttype" value="2"  <{if $selecttype == 2}>checked<{/if}> onclick="gotolink(this);">最近一周
            	 <input type="checkbox" name="selecttype" value="3"  <{if $selecttype == 3}>checked<{/if}> onclick="gotolink(this);">当天
 </div>
            <div id="con_one_1">

              <div class="table_td" style="margin-top:10px;">

         <div  id="container" style="min-width: 400px; height: 400px; margin: 0 auto">

              </div>



               <form method="post" action="" onsubmit="return remind();">
                  <table border="0" cellspacing="2" cellpadding="4" class="list" name="table" id="table" width="100%">
                    <thead>
                      <tr>
                        <th align="center">店铺名称</th>
                        <th align="center">销售数量</th>

                      </tr>
                    </thead>
                     <tbody>
                     	<{foreach from=$list item=items}>
                     	 <tr>

                        <td align="center"><{$items['shopname']}></td>
                        <td align="center"><{$items['shuliang']|default:'0'}></td>

                      </tr>
                      <{/foreach}>
                    </tbody>
                  </table>
               </form>



                <div class="page_newc">

                 </div>

                <div class="blank20"></div>

              </div>

            </div>

          </div>

        </div>


  </div>

</div>
 	<script type="text/javascript">
 		 var chart;

$(function () {


    $(document).ready(function() {
        chart = new Highcharts.Chart({
            chart: {
                renderTo: 'container',
                type: 'column'
            },
            title: {
                text: '店铺销售TOP10'
            },
            subtitle: {
                text: '<{$siteurl}>'
            },
            xAxis: {
                categories: [
                    '<{$typeshow}>'
                 ]
            },
            yAxis: {
                min: 0,
                title: {
                    text: '销量 (份)'
                }
            },
            legend: {
                layout: 'vertical',
                backgroundColor: '#FFFFFF',
                align: 'left',
                verticalAlign: 'top',
                x: 100,
                y: 70,
                floating: true,
                shadow: true
            },
            tooltip: {
                formatter: function() {
                    return '' + this.series.name+'销售: '+ this.y +' 份';
                }
            },
            plotOptions: {
                column: {
                    pointPadding: 0.2,
                    borderWidth: 0
                }
            },
                series: [
                <{foreach from=$list key=mykey item=items}>
                {  name: '<{$items['shopname']}>', data: [<{$items['shuliang']|default:'0'}>]  }<{if $mykey==count($list)-1}><{else}>,<{/if}>
               <{/foreach}>
               ]
        });
      });


});
		</script>
<!--newmain 结束-->
<{/block}>

